home *** CD-ROM | disk | FTP | other *** search
/ Web3D Graphics - Virtual Worlds Created With VRML / Web3D Graphics - Virtual Worlds Created With VRML.iso / List / Chap3 / list3-17.wrl < prev    next >
Encoding:
Text File  |  2000-10-12  |  3.0 KB  |  133 lines

  1. #VRML V2.0 utf8
  2.  
  3. Background{
  4.     skyColor [1 1 1]
  5. }
  6.  
  7. #ârâïé╠âvâìâgâ^âCâvÉΘî╛
  8. PROTO Building[
  9.     field  SFNode  lineColor  NULL
  10.     ]{
  11.     Shape{
  12.         geometry IndexedLineSet{
  13.             coord Coordinate{
  14.                 point[
  15.                      0  0  0,
  16.                     20  0  0,
  17.                     20  0 10,
  18.                      0  0 10,
  19.                      0 30  0,
  20.                     20 30  0,
  21.                     20 30 10,
  22.                      0 30 10
  23.                 ]
  24.             }
  25.             coordIndex[
  26.                 0 1 2 3 0 -1,
  27.                 4 5 6 7 4 -1, 
  28.                 0 4 -1,
  29.                 1 5 -1,
  30.                 2 6 -1,
  31.                 3 7 -1
  32.             ]
  33.             #Éⁿò¬é╔ÉFé≡òté»éΘ
  34.             colorPerVertex FALSE
  35.             color IS lineColor
  36.             colorIndex[
  37.                 0 0 0 0 0 0
  38.             ]
  39.         }
  40.     }
  41. }
  42. #.................................................
  43. #ârâïéPüiâvâìâgâ^âCâvé╠ê°ùpüj
  44. Transform{
  45.     translation 1 -3 -9
  46.     scale       0.2 0.2 0.2
  47.     children[
  48.         Building{
  49.             lineColor Color{
  50.                 color[1 0 0]
  51.             }
  52.         }
  53.     ]
  54. }
  55.  
  56. #ârâïéQüiâvâìâgâ^âCâvé╠ê°ùpüj
  57. Transform{
  58.     translation 1 -3 -5
  59.     scale       0.1 0.17 0.5
  60.     children[
  61.         Building{
  62.             lineColor Color{
  63.                 color[0 1 0]
  64.             }
  65.         }
  66.     ]
  67. }
  68.  
  69. #ârâïéRüiâvâìâgâ^âCâvé╠ê°ùpüj
  70. Transform{
  71.     translation -6 -3 -5
  72.     scale       0.25 0.15 0.3
  73.     children[
  74.         Building{
  75.             lineColor Color{
  76.                 color[0 0 1]
  77.             }
  78.         }
  79.     ]
  80. }
  81.  
  82. #ârâïéSüiâvâìâgâ^âCâvé╠ê°ùpüj
  83. Transform{
  84.     translation -4 -3 -9
  85.     scale       0.15 0.3 0.2
  86.     children[
  87.         Building{
  88.             lineColor Color{
  89.                 color[1 0 1]
  90.             }
  91.         }
  92.     ]
  93. }
  94. #.................................................
  95. #ô╣ÿHüiÆ╩Åφé╠ò√û@é╔éµéΘâÅâCâäü[âtâîü[âÇé╠É╢ɼüj
  96. Transform{
  97.     translation 0 -3 -6
  98.     scale       1 1 1
  99.     children[
  100.         Shape{
  101.             geometry IndexedLineSet{
  102.                 coord Coordinate{
  103.                     point[
  104.                          20 0   1,
  105.                           1 0   1,
  106.                           1 0  20,
  107.                          -1 0  20,
  108.                          -1 0   1,
  109.                         -20 0   1,
  110.                         -20 0  -1,
  111.                          -1 0  -1,
  112.                          -1 0 -20,
  113.                           1 0 -20,
  114.                           1 0  -1,
  115.                          20 0  -1
  116.                     ]
  117.                 }
  118.                 coordIndex[
  119.                     0  1  2 -1,
  120.                     3  4  5 -1,
  121.                     6  7  8 -1,
  122.                     9 10 11 -1 
  123.                 ]
  124.                 colorPerVertex FALSE
  125.                 color Color{
  126.                     color[ 0 0 0 ]
  127.                 }
  128.                 colorIndex[ 0 0 0 0 ]
  129.             }
  130.         }
  131.     ]
  132. }
  133.